<template>
  <div class="idassistant-container">
    <el-card class="main">
      <el-image></el-image>
      <el-input
        size="large"
        v-model="url"
      >
        <template #append>
          <el-button @click="handleCopy">复制</el-button>
        </template>
      </el-input>
    </el-card>
  </div>
</template>

<script setup>
import { ref } from "vue"
import { ElMessage } from "element-plus"
import { useClipboard } from "@vueuse/core"
import { handleCopyFunc } from "@/utils/copy"
const { copy } = useClipboard();
const url = ref("http://127.0.0.1:5173/#/manage/idassistant")
const handleCopy = () => {
  handleCopyFunc(url.value);
  ElMessage.success("复制成功")
}
</script>

<style lang="scss" scoped>
.idassistant-container {
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  .main {
    width: 512px;
    margin-top: 24px;
    border-radius: 16px;
    .el-image {
      width: 100%;
      height: 640px;
    }
    .el-input {
      margin-top: 16px;
    }
  }
}
</style>